package yf.mall.vo.up;


import lombok.Data;

import java.util.Date;

import com.alibaba.excel.annotation.*;

import java.io.Serializable;



import yf.mall.entity.DyAccountAuthEntity;
import yf.mall.vo.DyAccountAuthVo;

                                                                                
/**
 * 抖音账户授权表实体
 * 表名 dy_account_auth
 *
 *
 *
 * @date Thu Oct 26 15:41:58 CST 2023
 */
@Data
public class DyAccountAuthUp implements Serializable {
    @ExcelIgnore
    private static final long serialVersionUID = 1L;

                        //主键ID
            @ExcelProperty("主键ID")
            private Long id;
        
                        //用户id
            @ExcelProperty("用户id")
            private Long userId;
        
                        //授权时间
            @ExcelProperty("授权时间")
            private Date authTime;
        
                        //授权token
            @ExcelProperty("授权token")
            private String accessToken;
        
                        //授权token
            @ExcelProperty("授权token")
            private String refreshToken;
        
                        //原始有效期
            @ExcelProperty("原始有效期")
            private Integer expiresIn;
        
                        //刷新有效期
            @ExcelProperty("刷新有效期")
            private Integer refreshExpiresIn;
        
                        //备注
            @ExcelProperty("备注")
            private String remark;
        
                        //授权scope
            @ExcelProperty("授权scope")
            private String scope;
        
                        //openId
            @ExcelProperty("openId")
            private String openId;
        
                        //微信头像
            @ExcelProperty("微信头像")
            private String avatar;
        
                        //名称
            @ExcelProperty("名称")
            private String name;
        
                        //抖音号
            @ExcelProperty("抖音号")
            private String uid;
        
                        //是否主账号
            @ExcelProperty("是否主账号")
            private Integer master;
        
                        //用户名
            @ExcelProperty("用户名")
            private String userName;
        
                        //用户手机号
            @ExcelProperty("用户手机号")
            private String userMobile;
        
                        //抖音手机号
            @ExcelProperty("抖音手机号")
            private String dyMobile;
        
                        //抖音sec_uid
            @ExcelProperty("抖音sec_uid")
            private String secUid;
        
                        //下次刷新refreshtoken时间
            @ExcelProperty("下次刷新refreshtoken时间")
            private Date nextRenewRefreshTime;
        
                        //下次刷新accesstoken时间
            @ExcelProperty("下次刷新accesstoken时间")
            private Date nextRefreshTime;
        
    
    public DyAccountAuthUp() {

    }

    public DyAccountAuthVo toVo() {

        DyAccountAuthEntity entity = new DyAccountAuthEntity();
            DyAccountAuthVo vo = new DyAccountAuthVo(entity);
                                    entity.setId(id);
            
                                    entity.setUserId(userId);
            
                                    entity.setAuthTime(authTime);
            
                                    entity.setAccessToken(accessToken);
            
                                    entity.setRefreshToken(refreshToken);
            
                                    entity.setExpiresIn(expiresIn);
            
                                    entity.setRefreshExpiresIn(refreshExpiresIn);
            
                                    entity.setRemark(remark);
            
                                    entity.setScope(scope);
            
                                    entity.setOpenId(openId);
            
                                    entity.setAvatar(avatar);
            
                                    entity.setName(name);
            
                                    entity.setUid(uid);
            
                                    entity.setMaster(master);
            
                                    entity.setUserName(userName);
            
                                    entity.setUserMobile(userMobile);
            
                                    entity.setDyMobile(dyMobile);
            
                                    entity.setSecUid(secUid);
            
                                    entity.setNextRenewRefreshTime(nextRenewRefreshTime);
            
                                    entity.setNextRefreshTime(nextRefreshTime);
            
        
        return  vo;
    }



}
